var path = require('path');
var log4js = require('log4js');
var logger4js = log4js.getLogger('console');  //配置成console，会把所有的控制台打印包括 console.log()都记录到log文件中

log4js.configure({
    appenders: { cheese: { type: 'file', filename: 'log.log' },original_log:{type:'console',filename:'console.log'}},
    categories: { default: { appenders: ['cheese','original_log'], level: 'error' } }
    });

module.exports = {
    log4js: log4js,
    log4jsConfig: logger4js
};
